



import 'dart:io';

import 'package:erp/Events/EventAddrs.dart';
import 'package:erp/UI/Pages/SettingsPages/LogExplorerPage.dart';
import 'package:erp/global.dart';

void registerExceptionEvents(){
  globalBus.subscribe(Events.THROW_EXCEPTION, (bus, exception) async {
    log(exception);
    var file = await getLogFile();
    file.writeAsString(exception.toString() + "\n", mode: FileMode.append);

  });
}